import datetime
user_data = "zengqiaoyi"
password_data = "123456"

def login(username, password):
 count = 3
 while True:
  count -= 1
  if user_data == username:
    if password_data == password:
        print("欢迎%s登录课表系统使用~" % username)
        break
    else:
        if count == 0:
            print("您已输入三次错误账号或密码，还不对！笨死了~~~，别输了，5分钟后再来~~")
            break
        else:
            print("您输入的账号或密码不正确，请重新输入，您还有", count, "次机会~加油~")
  else:
    if count == 0:
        print("您已输入三次错误账号或密码，还不对！笨死了~~~，别输了，5分钟后再来~~")
        break
    else:
        print("您输入的账号或密码不正确，请重新输入，您还有", count, "次机会~加油~")

def School_timetable():
    print("秋季课程表")
    time = datetime.datetime.today().weekday()
    week_time = int(time)
    print("today:"), print(week_time)
    if week_time == 1:
        print("3-5 python语言")
        print("12-14 毛概理论")
    elif week_time == 2:
        print("4-5 广告学概论")
        print("8-10 网站运营与管理")
        print("12-13 大学英语")
    elif week_time == 3:
        print("1-2 排球")
        print("12-14 创业实践")
    elif week_time == 4:
        print("1-2 毛概实践")
        print("4-5 大学英语")
        print("8-9 广告文案")
    elif week_time == 5:
        print("没课啦~~~~~~")
    else:
        print("周末")
        print("HAPPY WEEKEND!")

answer = input("请问您是会员吗？yes/no:")
if answer == 'yes':
    temp = 0
    while temp < 10:
        temp = temp + 1
        ret = login(input("请输入您的账号："), input("请输入您的密码："))
        School_timetable()
elif answer == 'no':
    temp = 0
    while temp < 5:
        temp = temp + 1
        ret = login(input("请输入您的账号："), input("请输入您的密码："))
        School_timetable()
else:
    print("格式错误！")







